package org.gurms.dao.po.system;

import java.io.Serializable;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.GenericGenerator;

@Entity
@Table(name="sys_log")
@org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
public class SysLog implements Serializable {
	private String logid;
	private String userid;
	private String operatetime;
	private String menuid;
	private String userip;
	private int    operateid;

	@Id
	@GeneratedValue(generator = "uuid")    
	@GenericGenerator(name = "uuid", strategy = "uuid") 
	public String getLogid() {
		return logid;
	}

	public void setLogid(String logid) {
		this.logid = logid;
	}

	public String getUserid() {
		return userid;
	}

	public void setUserid(String userid) {
		this.userid = userid;
	}

	public String getOperatetime() {
		return operatetime;
	}

	public void setOperatetime(String operatetime) {
		this.operatetime = operatetime;
	}

	public String getMenuid() {
		return menuid;
	}

	public void setMenuid(String menuid) {
		this.menuid = menuid;
	}

	public int getOperateid() {
		return operateid;
	}

	public void setOperateid(int operateid) {
		this.operateid = operateid;
	}

	public String getUserip() {
		return userip;
	}

	public void setUserip(String userip) {
		this.userip = userip;
	}
	
	public boolean equals(Object o){
		if(o == null || !(o instanceof SysLog)){
			return false;
		}else{
			SysLog log = (SysLog)o;
			if(log.getLogid() == null){
				return false;
			}else{
				return log.getLogid().equals(logid);
			}
		}
	}
	
	public int hashCode(){
		if(logid == null)
			return super.hashCode();
		return logid.hashCode();
	}
}
